﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Serialization;
namespace Fcdbas.Biz
{
    [Serializable()]
    public class FndOption
    {
        public FndOption()
        {
            this.DefaultHome = "";
            this.DateFormat = "";
            this.DAlign = new Fcdbas.WinUI.Controls.ComboBoxData(DevExpress.Utils.HorzAlignment.Far, "右边");
            this.DateTimeFormat = "";
            this.DeleteColor = System.Drawing.Color.Black;
            this.EditColor = System.Drawing.Color.Black;
            this.FocusColor = System.Drawing.Color.White;
            this.FontName = "Arial";
            this.FontSize = 9F;
            this.MandatoryColor = System.Drawing.Color.Blue;
            this.NAlign = new Fcdbas.WinUI.Controls.ComboBoxData(DevExpress.Utils.HorzAlignment.Near, "左边");
            this.SAlign = new Fcdbas.WinUI.Controls.ComboBoxData(DevExpress.Utils.HorzAlignment.Far, "右边");
            this.TimeFormat = "";
            this.AlarmEnable = false;
            this.AlarmRiseTime = 10;
        }
        public string DefaultHome
        {
            get;
            set;
        }
        public string DateFormat
        {
            get;
            set;
        }
        public string TimeFormat
        {
            get;
            set;
        }
        public string DateTimeFormat
        {
            get;
            set;
        }
        public bool AlarmEnable
        {
            get;
            set;
        }
        public int AlarmRiseTime
        {
            get;
            set;
        }
        public Fcdbas.WinUI.Controls.ComboBoxData DAlign
        {
            get;
            set;
        }

        public Fcdbas.WinUI.Controls.ComboBoxData NAlign
        {
            get;
            set;
        }
        public Fcdbas.WinUI.Controls.ComboBoxData SAlign
        {
            get;
            set;
        }
        public int iReadOnlyColor
        {
            get
            {
                return System.Drawing.ColorTranslator.ToWin32(this.ReadOnlyColor);
            }
            set
            {
                this.ReadOnlyColor = System.Drawing.ColorTranslator.FromWin32(value);
            }
        }
        public int iDeleteColor
        {
            get
            {
                return System.Drawing.ColorTranslator.ToWin32(this.DeleteColor);
            }
            set
            {
                this.DeleteColor = System.Drawing.ColorTranslator.FromWin32(value);
            }
        }
        public int iEditColor
        {
            get
            {
                return System.Drawing.ColorTranslator.ToWin32(this.EditColor);
            }
            set
            {
                this.EditColor = System.Drawing.ColorTranslator.FromWin32(value);
            }
        }
        public int iMandatoryColor
        {
            get
            {
                return System.Drawing.ColorTranslator.ToWin32(this.MandatoryColor);
            }
            set
            {
                this.MandatoryColor = System.Drawing.ColorTranslator.FromWin32(value);
            }
        }
        public int iFocusColor
        {
            get
            {
                return System.Drawing.ColorTranslator.ToWin32(this.FocusColor);
            }
            set
            {
                this.FocusColor = System.Drawing.ColorTranslator.FromWin32(value);
            }
        }

        public int iOddColor
        {
            get
            {
                return System.Drawing.ColorTranslator.ToWin32(this.OddColor);
            }
            set
            {
                this.OddColor = System.Drawing.ColorTranslator.FromWin32(value);
            }
        }
        public int iEvenColor
        {
            get
            {
                return System.Drawing.ColorTranslator.ToWin32(this.EvenColor);
            }
            set
            {
                this.EvenColor = System.Drawing.ColorTranslator.FromWin32(value);
            }
        }
        public string FontName
        {
            get;
            set;
        }
        public float FontSize
        {
            get;
            set;
        }
        [NonSerialized()]
        private System.Drawing.Color _ReadOnlyColor;
        [XmlIgnore()]
        public System.Drawing.Color ReadOnlyColor
        {
            get{
                return _ReadOnlyColor;
            }
            set
            {
                _ReadOnlyColor = value;
            }
        }
        [NonSerialized()]
        private System.Drawing.Color _EditColor;
        [XmlIgnore()]
        public System.Drawing.Color EditColor
        {
            get
            {
                return _EditColor;
            }
            set
            {
                _EditColor = value;
            }
        }
        private System.Drawing.Color _MandatoryColor;
        [XmlIgnore()]
        public System.Drawing.Color MandatoryColor
        {
            get
            {
                return _MandatoryColor;
            }
            set
            {
                _MandatoryColor = value;
            }
        }
        [NonSerialized()]
        private System.Drawing.Color _DeleteColor;
        [XmlIgnore()]
        public System.Drawing.Color DeleteColor
        {
            get
            {
                return _DeleteColor;
            }
            set
            {
                _DeleteColor = value;
            }
        }
        [NonSerialized()]
        private System.Drawing.Color _FocusColor;
        [XmlIgnore()]
        public System.Drawing.Color FocusColor
        {
            get
            {
                return _FocusColor;
            }
            set
            {
                _FocusColor = value;
            }
        }
        [NonSerialized()]
        private System.Drawing.Color _OddColor;
        [XmlIgnore()]
        public System.Drawing.Color OddColor
        {
            get
            {
                return _OddColor;
            }
            set
            {
                _OddColor = value;
            }
        }

        [NonSerialized()]
        private System.Drawing.Color _EvenColor;
        [XmlIgnore()]
        public System.Drawing.Color EvenColor
        {
            get
            {
                return _EvenColor;
            }
            set
            {
                _EvenColor = value;
            }
        }
    }
}
